ARCH_NAME := arm
ISET_NAME := armv5

ARCH_INCS_ROOT := ../arch/$(ARCH_NAME)/$(ISET_NAME)/h
ARCH_SRCS_ROOT := ../arch/$(ARCH_NAME)/$(ISET_NAME)/src/

ARCH_INCS := $(ARCH_INCS_ROOT)
ARCH_SRCS := $(ARCH_SRCS_ROOT)

ARCH_ALL_INCS := $(ARCH_INCS)
ARCH_ALL_SRCS := $(ARCH_SRCS)

INC_DIRS := $(ARCH_ALL_INCS)
SRC_DIRS := $(ARCH_ALL_SRCS)

H_FILES := $(patsubst %, -I %, $(INC_DIRS))
C_FILES := $(SRC_DIRS)
S_FILES := $(SRC_DIRS)

CBUILD_PATH = $(C_FILES)
SBUILD_PATH = $(S_FILES)
HEADFILE_PATH = $(H_FILES)

# 编译生成文件存储路径
OBJOUT_PATH = ../build/obj

include buildcmd.mki
include buildobjs.mki

# 目标依赖关系
.PHONY : all everything build_arch

all : build_arch
build_arch : everything
everything : $(BUILD_MK_ARCH_OBJS)

include buildrule.mki